#!/bin/bash

result=$(ps -eLf |grep paddleocr |wc -l)

echo $result

if [ "$result"  -lt  10000 ]; then
  echo "ocr running"
else
  echo "ocr restarting" && \
  docker restart ocr && \
  docker restart ocr1 && \
  docker restart ocr2 && \
  echo "ocr restart success"
fi